﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Navigation;
using Microsoft.Phone.Controls;
using Microsoft.Phone.Shell;
using Trotware.Model;
using Trotware.Resources;

namespace Trotware.View
{
    public partial class DetailColis : PhoneApplicationPage
    {
        String desti;
        String addr;
        String c_id;


        public DetailColis()
        {
            InitializeComponent();
            List<String> source = new List<String>();
            source.Add("En cours de livraison");
            source.Add("Livré");
            source.Add("Absent");
            source.Add("Refusé");
            source.Add("Attente pick up");
            source.Add("Picked");
            source.Add("Au dépot");
            
            this.comandState.ItemsSource = source;
        }

        protected override void OnNavigatedTo(NavigationEventArgs e)
        {
            if (e.NavigationMode == NavigationMode.Back) return;


            NavigationContext.QueryString.TryGetValue("destinataire", out desti);
            NavigationContext.QueryString.TryGetValue("address", out addr);
            NavigationContext.QueryString.TryGetValue("id", out c_id);
            ColisNumber.Text = c_id;
            AddressColis.Text = addr;
            DestinataireColis.Text = desti;

        }



    }
}